﻿using System;

namespace ExpressesClass.KyApi.Util
{
    public class ConfigUrl
    {
        public static String GetTokenUrl()
        {
            //测试
            //return "https://open.ky-express.com/security/sandbox/accessToken";
            //正式
            return "https://open.ky-express.com/security/token";
        }

        public static String GetUrl()
        {
            //测试
            //return "https://open.ky-express.com/sandbox/router/rest";
            //正式
            return "https://open.ky-express.com/router/rest";
        }

        public static String GetMethodCode(String appName)
        {
            switch (appName)
            {
                case "CREATE":
                    return "open.api.openCommon.planOrder";
                case "CANCEL":
                    return "open.api.openCommon.cancelOrder";
                case "TRACE":
                    return "open.api.openCommon.queryPublicRoute";
                case "PRINT":
                    return "open.api.openCommon.print";
                default:
                    return "";
            }
        }
    }
}
